

def sum(a,b,*abc):
    print(abc)
    c = a + b
    return c


print(sum(1,2,3,4,5,6,7))

n = int(input("Type n:"))
total = 0
for i in range(1,n+1):
    total += i**2
print(total)



total = 0

list1 = [11, 5, 17, 18, 23]

for ele in range(0, len(list1)):
    total = total + list1[ele]

print("列表元素之和为: ", total)


def sum2(*abc):
    sum = 0
    for a in abc:
        sum += a
    return sum
print( 'sum2',sum2(3232))
print("sum2(1)",sum2(234,3245))


def fun3(**a):
    print(a)

fun3(a=1,b=2,c=3)


mul = lambda a,b: a*b
print(mul(33,44))


a = 5
print('前---',id(a))
a = 10
print('后---',id(a))

list1 = [1,2,'hello']
print('前---',id(list1))
list1[0] = 'hello'
print('前---',id(list1))